
<%@ page import="comptadub.Parametre" %>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <meta name="layout" content="admin" />
        <title><g:message code="parametre.list.label" /></title>
    </head>

    <body>
        <div class="nav">
            <span class="menuButton"><g:link class="admin" controller="parametre" action="list"><g:message code="default.admin.label" /></g:link></span>
            <span class="menuButton"><g:link class="list" controller="membre" action="list">Liste des membres</g:link></span>
            <span class="menuButton"><g:link class="list" controller="typeMembre" action="list">Types de membres</g:link></span>
            <span class="menuButton"><g:link class="list" controller="typePaiement" action="list">Types de paiement</g:link></span>
        </div>

        <div class="body">
            <h1><g:message code="parametre.list.label" /></h1>

            <g:if test="${flash.message}">
                <div class="message">${flash.message}</div>
            </g:if>

            <div class="list">
                <table>
                    <thead>
                        <tr>                        
                            <g:sortableColumn property="id" title="${message(code: 'parametre.id.label', default: 'Id')}" />                        
                            <g:sortableColumn property="nom" title="${message(code: 'parametre.nom.label', default: 'Nom')}" />                        
                            <g:sortableColumn property="valeur" title="${message(code: 'parametre.valeur.label', default: 'Valeur')}" />
                            <g:sortableColumn property="description" title="${message(code: 'parametre.description.label', default: 'Description')}" />
                            <th />
                        </tr>
                    </thead>

                    <tbody>
                    <g:each in="${parametreInstanceList}" status="i" var="parametreInstance">
                        <tr class="${(i % 2) == 0 ? 'odd' : 'even'}">                        
                            <td>${fieldValue(bean: parametreInstance, field: "id")}</td>                        
                            <td>${fieldValue(bean: parametreInstance, field: "nom")}</td>
                            <td>${fieldValue(bean: parametreInstance, field: "valeur")}</td>
                            <td>${fieldValue(bean: parametreInstance, field: "description")}</td>
                            <td width="20px">
                                <g:link action="edit" id="${parametreInstance.id}">
                                    <img src="${createLinkTo(dir:'images/skin',file:'pencil.png')}" alt="Modifier" />
                                </g:link>
                            </td>
                        </tr>
                    </g:each>
                    </tbody>
                </table>
            </div>
            
            <div class="paginateButtons">
                <g:paginate total="${parametreInstanceTotal}" />
            </div>
        </div>
    </body>
</html>
